<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN"
        "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
<html xmlns="http://www.w3.org/1999/xhtml">
<head>
    <meta http-equiv="Content-Type" content="text/html; charset=utf-8"/>
    <include file="Public/title"/>
    <style type="text/css">
        .search {
            float: right;
            margin-right: 30px;
        }
    </style>
</head>
<body>
<div class="mainWrap">
    <div class="mainWrapBd">
        <div class="mainListTit">
            <a href="{:U('add')}" class="btn btn_edit"><span>添加物料</span></a>
        </div>
        

        <form action="{:U('batchDo')}" method="post" name="doForm" onsubmit="return batchConfirm(this);">
            <!--列表-->
            <table cellpadding="0" cellspacing="0" border="0" class="stdtable stdtablelist">
                <thead>
                <tr>
                    <!-- <th class="center"><input type="checkbox" class="checkall" /></th> -->
                    <th class="center">ID</th>
                    <th>物料名称</th>
                    <th>物料价格</th>
                    <th>添加时间</th>
                    <th>状态</th>
                    <th>操作</th>
                </tr>
                </thead>
                <tbody>
                <volist name="pages['lists']" id="fo">
                    <tr>
                        <td align="center">{$fo['id']}</td>
                        <td>{$fo['name']}</td>
                        <td>{$fo['price']}</td>
                        <td>{$fo['add_time'] | date="Y-m-d H:i:s",###}</td>
                        <td>
                            <if condition="$fo['status'] eq 1">
                                可用
                                <elseif condition="$fo['status'] eq 0"/>
                                不可用
                                <else/>
                                未知状态
                            </if>
                        </td>
                        <td>
                            <a href="{:U('detail',array('id'=>$fo['id']))}">查看详情</a> &nbsp;
                            <a href="{:U('upd',array('id'=>$fo['id']))}">修改</a> &nbsp;
                            <a href="{:U('delete',array('id'=>$fo['id']))}" onclick="return confirm('确认删除吗？')">删除</a> &nbsp;
                        </td>
                    </tr>
                </volist>
                <if condition="$pages['total'] eq 0">
                    <tr>
                        <td align="center" class="data-nothing" colspan="9">暂无相关信息</td>
                    </tr>
                </if>
                </tbody>
            </table>
            <!--列表-->
            <!--工具-->
            <div class="tableTools clearfix">
                <div class="tableOptions fl">
                </div>
                <div class="fr">
                    {$pages['show']}
                </div>
            </div>
            <!--工具-->
        </form>
    </div>
</div>
</body>
</html>